home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 26 / Cream of the Crop 26.iso / program / recom11.zip / RECOM.DOC < prev    next >
Text File  |  1997-07-01  |  3KB  |  88 lines

  1.                       ******* ReCom 1.1 *******
  2.  
  3. Recomments C/C++/ASM/BASIC Headers and Source Files, as well as GW-BASIC,
  4. *.SYS (ie. CONFIG.SYS), BATch and Windows INI files. Example: You want
  5. to comment each line of a C program so you can load it into QuickBasic and
  6. work on each line to convert it to QuickBasic. You would do this:
  7.  
  8.                     recom /qs hello.c
  9.  
  10. This says to take the file hello.c and recomment each line with a ' and
  11. have the output file named hello.bas. The original source is supposed to
  12. be (and usually is) left untouched (unless some unforseen error I refuse
  13. to be held responsible for happens).
  14.  
  15. History & Credits:
  16.  
  17. 1.0
  18.    I lost the original source code to this one and it didn't have any file
  19.    checking capabilities.
  20. 1.1
  21.    I rewrote this from memory (not the computer's :) and I think I added
  22.    some more user error checking and file checking (can't recomment a C
  23.    file to a C Source file, for example). I think Joe Negron is the one
  24.    who wrote the Exist code (checks to see if a file exists). I know I
  25.    got it from a post in the QUIK_BAS FidoNet echo.
  26.  
  27. QUIRKS in the source/operation:
  28.   /g, /b, /i, /s: if you pass another letter with it (ie. /gh) then the
  29.   file is processed and the second letter ignored. However, due to some
  30.   parameter checking, you will get a help screen and no conversion if
  31.   you pass a /ss (since both the Lang$ and Source$ are the same). Some may
  32.   prefer to fix this quirk. I didn't think it would be a problem though
  33.   as you're really only supposed to use the one letter anyway. :)
  34.  
  35.   If you are converting an ANSI C source to an ANSI C header, no conversion
  36.   is made. Basically, it just copies the file to another *.H file. I
  37.   figured for that, you might not even use this utility, just rename or
  38.   copy the source. It would take more code to parse out comments in the
  39.   C Source and adjust while commenting the header. Something I'm not up
  40.   to but if anyone else would like to add it in, feel free to do so.
  41.  
  42. USAGE: recom /switch infile.ext
  43.  
  44. infile.ext is the filename and extension of the source code file you want
  45. to convert. The output file is determined by the use of one of the
  46. following switches (only one switch can be used):
  47.  
  48. /qx  QBasic/QuickBasic 4.5
  49. /cx  ANSI C
  50. /px  C++
  51. /ax  Assembly Language
  52. /g   GWBASIC
  53. /b   Batch File (.BAT)
  54. /i   .INI File
  55. /s   .SYS File
  56.  
  57. NOTE: x must be either an 's' (for source) or 'h' (for header)
  58.  
  59. Here's a chart of what can be converted:
  60. (Note that QB stands for QuickBasic 4.5 or QBasic 1.1)
  61.  
  62. Destination File      Switch Used
  63. QB *.BAS              /qs
  64. QB *.BI               /qh
  65. ANSI C *.c            /cs
  66. ANSI C *.h            /ch
  67. C++ *.CPP             /ps
  68. C++ Header *.H        /ph
  69. Assembly *.ASM        /as
  70. Assebmly *.INC        /ah
  71. GW-BASIC  *.BAS       /g
  72. Batch File *.BAT      /b
  73. Windows *.INI         /i
  74. CONFIG.SYS (or *.sys) /s
  75.  
  76. DISCLAIMER:
  77. ReCom 1.1 is distributed on an "AS IS" basis. The author(s) disclaim all
  78. warranties, expressed or implied, including but not limited to the
  79. warranties of merchantability and of fitness for any purpose. The author(s)
  80. assume no liability for damages, direct or consequential, which may
  81. result from use of this program or any accompanying source(s).
  82.  
  83. CONTACT:
  84. Tika Carr
  85.  FidoNet: 1:2613/313 or 1:2613/601
  86. Internet: t.carr@pobox.com
  87.  
  88.